package com.platform.common.utils;

/**
 * 常量
 *
 * @author 肖亮
 */
public class Constant {
	/**
	 * 超级管理员ID
	 */
	public static final String SUPER_ADMIN = "1";
	/**
	 * 超级管理员所属机构
	 */
	public static final String SUPER_ADMIN_ORG = "01";

	public static final String DEFAULT_PW = "123456";

	/**
	 * 6小时后过期
	 */
	public static final int EXPIRE = 3600 * 6;

	/**
	 * 云存储配置KEY
	 */
	public final static String CLOUD_STORAGE_CONFIG_KEY = "CLOUD_STORAGE_CONFIG_KEY";

	/**
	 * 短信配置KEY
	 */
	public final static String SMS_CONFIG_KEY = "SMS_CONFIG_KEY";

	/**
	 * 权限前缀
	 */
	public static final String SESSION = "SESSION:";

	/**
	 * 系统缓存前缀
	 */
	public static final String SYS_CACHE = "SYS_CACHE:";

	/**
	 * 业务系统缓存前缀
	 */
	public static final String MTM_CACHE = "MTM_CACHE:";

	public static final String STR_ZERO = "0";
	public static final String STR_ONE = "1"; //所有缓存
	public static final String STR_TWO = "2"; //session缓存
	public static final String STR_THREE = "3"; //系统缓存
	public static final String STR_FOUR = "4"; //业务缓存

	public static final int ONE = 1;
	public static final int TWO = 2;
	public static final int THREE = 3;
	/**
	 * 空字符串
	 */
	public static final String BLANK = "";
	/**
	 * 斜杠
	 */
	public static final String SLASH = "/";
	/**
	 * 逗号
	 */
	public static final String COMMA = ",";
	/**
	 * 句号
	 */
	public static final String DOT = ".";
	/**
	 * 冒号
	 */
	public static final String COLON = ":";
	/**
	 * 下划线
	 */
	public static final String UNDERSCORE = "_";
	/**
	 * 换行符
	 */
	public static final String LINE_BREAK = "\\r\\n";

	public static final String ACCESS_TOKEN = "ACCESS_TOKEN";

	public static final String BPMN20 = ".bpmn20.xml";

	public static final String IMAGE = "image";

	public static final String XML = "xml";
	public static final String PNG = "png";
	public static final String BAR = "bar";
	public static final String ZIP = "zip";
	public static final String BPMN = "bpmn";

	/**
	 * 系统邮件签名
	 */
	public static final String SIGNATURE_STR = "<br><font color='red'>-------------------------------------------------------------------<br>以上内容为邮件系统自动发送，请勿直接回复。</font>";
	public static final String EMAIL_HTML_REG="		<!DOCTYPE html>"
	+"<html lang=\"en\">"
	+"<head>"
	+"<meta charset=\"UTF-8\">"
	+"<title>Title</title>"
	+"</head>"
	+"<body>"
	+"<h1 style=\"color:blue;\">{emailTile}</h1>"
	+"<p style=\"line-height:30px;\">点击以下链接进行账号验证</p >"
	+"<p style=\"line-height:30px;margin-bottom:10px;\">"
	+"    <a style\"color:blue;\""
	+"       target=\"_blank\""
	+ "		 href=\" {webUrl}/{emailParameter}?sign={sign}&orgNo={orgNo}&orgLinkMailbox={orgLinkMailbox}\">"
	+"        {webUrl}/{emailParameter}?sign={sign}&orgNo={orgNo}&orgLinkMailbox={orgLinkMailbox}"
	+"    </a>"
	+"</p >"
	+"<p>如果您没有注册该系统账号，可以忽略该电子邮件。</p >"
	+"<p>谢谢!</p >"
	+"<p style=\"line-height:30px;font-weight: bold;\">{emailTile}</p >"
	+"</body>"
	+"</html>";
	
	
	public static final String EMAIL_HTML_REG_SHTG="		<!DOCTYPE html>"
	+"<html lang=\"en\">"
	+"<head>"
	+"<meta charset=\"UTF-8\">"
	+"<title>Title</title>"
	+"</head>"
	+"<body>"
	+"<h1 style=\"color:blue;\">{emailTile}</h1>"
	+"<p style=\"line-height:30px;\">审核人：{auditor}</p >"
	+"<p style=\"line-height:30px;\">审核时间：{auditTime}</p >"
	+"<p style=\"line-height:30px;\">审核意见：{auditTxt}</p >"
	+"<p style=\"line-height:30px;\">审核结果：{auditStatus}</p >"
	+"<p style=\"line-height:30px;\">登陆账号：{userName}</p >"
	+"<p style=\"line-height:30px;\">点击以下链接进行登陆</p >"
	+"<p style=\"line-height:30px;margin-bottom:10px;\">"
	+"    <a style\"color:blue;\""
	+"       target=\"_blank\""
	+ "		 href=\" {webUrl}/{tgEmailParameter}?orgNo={orgNo}\">"
	+"        {webUrl}/{tgEmailParameter}?orgNo={orgNo}"
	+"    </a>"
	+"</p >"
	+"<p>如果您没有注册该系统账号，可以忽略该电子邮件。</p >"
	+"<p>谢谢!</p >"
	+"<p style=\"line-height:30px;font-weight: bold;\">{emailTile}</p >"
	+"</body>"
	+"</html>";
	
	public static final String EMAIL_HTML_REG_SHBTG ="		<!DOCTYPE html>"
			+"<html lang=\"en\">"
			+"<head>"
			+"<meta charset=\"UTF-8\">"
			+"<title>Title</title>"
			+"</head>"
			+"<body>"
			+"<h1 style=\"color:blue;\">{emailTile}</h1>"
			+"<p style=\"line-height:30px;\">审核人：{auditor}</p >"
			+"<p style=\"line-height:30px;\">审核时间：{auditTime}</p >"
			+"<p style=\"line-height:30px;\">审核意见：{auditTxt}</p >"
			+"<p style=\"line-height:30px;\">审核结果：{auditStatus}</p >"
			+"<p style=\"line-height:30px;\">点击以下链接再次编辑</p >"
			+"<p style=\"line-height:30px;margin-bottom:10px;\">"
			+"    <a style\"color:blue;\""
			+"       target=\"_blank\""
			+ "		 href=\" {webUrl}/{btgEmailParameter}?orgNo={orgNo}\">"
			+"        {webUrl}/{btgEmailParameter}?orgNo={orgNo}"
			+"    </a>"
			+"</p >"
			+"<p>如果您没有注册该系统账号，可以忽略该电子邮件。</p >"
			+"<p>谢谢!</p >"
			+"<p style=\"line-height:30px;font-weight: bold;\">{emailTile}</p >"
			+"</body>"
			+"</html>";
	
	
	/**
	 * 系统自动邮件
	 */
	public static final int SYS_SEND = 0;
	/**
	 * 操作人主动邮件
	 */
	public static final int USER_SEND = 1;

	/**
	 * 菜单类型
	 */
	public enum MenuType {
		/**
		 * 目录
		 */
		CATALOG(0),
		/**
		 * 菜单
		 */
		MENU(1),
		/**
		 * 按钮
		 */
		BUTTON(2);

		private int value;

		MenuType(int value) {
			this.value = value;
		}

		public int getValue() {
			return value;
		}
	}

	/**
	 * 定时任务状态
	 */
	public enum ScheduleStatus {
		/**
		 * 正常
		 */
		NORMAL(0),
		/**
		 * 暂停
		 */
		PAUSE(1);

		private int value;

		ScheduleStatus(int value) {
			this.value = value;
		}

		public int getValue() {
			return value;
		}
	}

	/**
	 * 云服务商
	 */
	public enum CloudService {
		/**
		 * 七牛云
		 */
		QINIU(1),
		/**
		 * 阿里云
		 */
		ALIYUN(2),
		/**
		 * 腾讯云
		 */
		QCLOUD(3),
		/**
		 * 服务器存储
		 */
		DISCK(4),
		/**
		 * FastDFS
		 */
		FAST_DFS(5);

		private int value;

		CloudService(int value) {
			this.value = value;
		}

		public int getValue() {
			return value;
		}
	}

}
